import { createRouter,createWebHashHistory } from 'vue-router'
import home from '../views/management/home.vue'

const routes = [
  {
    path:'/',
    name:'v_login',
    component:()=>import(/*webpackChunkName:'Login'*/ '../views/v_login/v_login.vue')
  },

  {
    path:'/regist',
    name:'v_regist',
    component:()=>import(/*webpackChunkName:'Regist'*/ '../views/v_login/v_regist.vue'),

  },

  {
    path:'/m_login',
    name:'m_login',
    component:()=>import(/*webpackChunkName:'Regist'*/ '../views/v_login/m_login.vue'),
  },

  {//主见面
    path:'/index',
    name:'index',
    component:()=>import(/*webpackChunkName:'index'*/ '../views/index/index.vue'),

  },

    {
      path:'/ISTJ',
      name:'ISTJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ISTJ.vue'),
  
    },

    {
      path:'/ISTP',
      name:'ISTP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ISTP.vue'),
  
    },

    {
      path:'/ISFP',
      name:'ISFP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ISFP.vue'),
  
    },

    {
      path:'/ISFJ',
      name:'ISFJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ISFJ.vue'),
  
    },

    {
      path:'/INTP',
      name:'INTP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/INTP.vue'),
  
    },

    {
      path:'/INTJ',
      name:'INTJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/INTJ.vue'),
  
    },

    {
      path:'/INFP',
      name:'INFP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/INFP.vue'),
  
    },

    {
      path:'/INFJ',
      name:'INFJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/INFJ.vue'),
  
    },

    {
      path:'/ESTP',
      name:'ESTP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ESTP.vue'),
  
    },

    {
      path:'/ESFP',
      name:'ESFP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ESFP.vue'),
  
    },

    {
      path:'/ESFJ',
      name:'ESFJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ESFJ.vue'),
  
    },

    {
      path:'/ENTP',
      name:'ENTP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ENTP.vue'),
  
    },

    {
      path:'/ENTJ',
      name:'ENTJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ENTJ.vue'),
  
    },

    {
      path:'/ENFP',
      name:'ENFP',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ENFP.vue'),
  
    },

    {
      path:'/ENFJ',
      name:'ENFJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ENFJ.vue'),
  
    },

    {
      path:'/ESTJ',
      name:'ESTJ',
      component:()=>import(/*webpackChunkName:'index'*/ '../views/result/ESTJ.vue'),
  
    },




  {
    path: '/home',
    name: 'home',
    component: () => import(/* webpackChunkName: "Home" */ '../views/management/home.vue'),
    redirect:'/student',

    children: [
      {
        path: '/student',
        name: 'student',
        component: () => import(/* webpackChunkName: "Student" */ '../views/management/student.vue'),

      },

      {
        path: '/class',
        name: 'class',
        component: () => import(/* webpackChunkName: "Student" */ '../views/management/class.vue'),
      },

      {
        path: '/add_student',
        name: 'add_student',
        component: () => import(/* webpackChunkName: "Student" */ '../views/management/add_student'),
      },

      {
        path: '/view_student',
        name: 'view_student',
        component: () => import(/* webpackChunkName: "Student" */ '../views/management/view_student.vue'),
      },

      {
        path: '/view_class',
        name: 'view_class',
        component: () => import(/* webpackChunkName: "Student" */ '../views/management/view_class.vue'),
      }




     ]
  },

  




 ]

const router = createRouter({
  //内部提供了history 模式的实现。为了简单起见，在这里使用hash模式
  history: createWebHashHistory(),
  routes,
})

export default router
